import request from '@/utils/request'

export function listTenant(query) {
  return request({
    url: '/system/tenant/list',
    method: 'get',
    params: query
  })
}

export function getTenant(userId) {
  return request({
    url: `/system/tenant/${userId}`,
    method: 'get'
  })
}

export function changeTenantStatus(userId, status) {
  return request({
    url: `/system/tenant/${userId}/status`,
    method: 'put',
    data: { status }
  })
}
